﻿// Decompiled with JetBrains decompiler
// Type: SuperMiner.DoPostConfigureComplete
// Assembly: MG_SuperMiner, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null
// MVID: 4DA81FE3-ADC7-45B4-A911-3493B5D525DE
// Assembly location: E:\docs\Klei\OxygenNotIncluded\mods\Steam\2558070245\MG_SuperMiner.dll

using HarmonyLib;
using UnityEngine;

namespace SuperMiner
{
  [HarmonyPatch("DoPostConfigureComplete")]
  [HarmonyPatch(typeof (AutoMinerConfig))]
  public static class DoPostConfigureComplete
  {
    private static void Postfix(GameObject go)
    {
      go.AddOrGet<LogicOperationalController>();
      AutoMiner autoMiner = go.AddOrGet<AutoMiner>();
      autoMiner.width = AdvancedRoboMinerRange.width;
      autoMiner.height = AdvancedRoboMinerRange.height;
      autoMiner.x = AdvancedRoboMinerRange.xOffset;
      autoMiner.y = AdvancedRoboMinerRange.yOffset;
      autoMiner.vision_offset = AdvancedRoboMinerRange.VisionOffset;
    }
  }
}
